package com.wu.server.dao;

import com.wu.server.entity.Shop;
import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.CrudRepository;
import org.springframework.stereotype.Repository;

/**
 * @author Wugs
 * @version 1.0
 * @date 2021/3/6 15:11
 */
@Repository
public interface ShopRepository extends CrudRepository<Shop, Integer> {
    @Query(value = "select * from jd_shop.shop order by shop_sales desc limit 10;",nativeQuery = true)
    Iterable<Shop> getShopList();
}
